<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="utf-8">
	<title>MorphBlendMesh - Three.js Docs</title>
	<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
	<script src="../scripts/highlight.min.js"></script>
	<link type="text/css" rel="stylesheet" href="../styles/highlight-three.css">
	<link type="text/css" rel="stylesheet" href="../styles/page.css">
</head>
<body>
		<p class="inheritance" translate="no"><a href="EventDispatcher.html">EventDispatcher</a> → <a href="Object3D.html">Object3D</a> → <a href="Mesh.html">Mesh</a> → </p>
	<h1 translate="no">MorphBlendMesh</h1>
		<section>
			<header>
				<div class="class-description"><p>A special type of an animated mesh with a more advanced interface
for animation playback. Unlike <a href="MorphAnimMesh.html">MorphAnimMesh</a>. It allows to
playback more than one morph animation at the same time but without
fading options.</p></div>
			</header>
			<article>
				<h2 class="subsection-title">Import</h2>
				<p><span translate="no">MorphBlendMesh</span> is an addon, and must be imported explicitly, see <a href="https://threejs.org/manual/#en/installation" target="_blank" rel="noopener">Installation#Addons</a>.</p>
				<pre><code class="language-js">import { MorphBlendMesh } from 'three/addons/misc/MorphBlendMesh.js';</code></pre>
				<div class="container-overview">
					<h2>Constructor</h2>
					<h3 class="name name-method" id="MorphBlendMesh" translate="no">new <a href="#MorphBlendMesh">MorphBlendMesh</a><span class="signature">( geometry : <span class="param-type"><a href="BufferGeometry.html">BufferGeometry</a></span>, material : <span class="param-type"><a href="Material.html">Material</a> | Array.&lt;<a href="Material.html">Material</a>></span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Constructs a new morph blend mesh.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>geometry</strong>
									</td>
									<td class="description last">
										<p>The mesh geometry.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>material</strong>
									</td>
									<td class="description last">
										<p>The mesh material.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
				</div>
				<h2 class="subsection-title">Properties</h2>
				<div class="member">
					<h3 class="name" id="animationsList" translate="no">.<a href="#animationsList">animationsList</a><span class="type-signature"> : Array.&lt;Object></span> </h3>
					<div class="description">
						<p>A list of animations.</p>
					</div>
				</div>
				<div class="member">
					<h3 class="name" id="animationsMap" translate="no">.<a href="#animationsMap">animationsMap</a><span class="type-signature"> : Object.&lt;string, Object></span> </h3>
					<div class="description">
						<p>A dictionary of animations.</p>
					</div>
				</div>
				<h2 class="subsection-title">Methods</h2>
					<h3 class="name name-method" id="autoCreateAnimations" translate="no">.<a href="#autoCreateAnimations">autoCreateAnimations</a><span class="signature">( fps : <span class="param-type">number</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Automatically creates animations based on the values in
<a href="Mesh.html#morphTargetDictionary">Mesh#morphTargetDictionary</a>.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>fps</strong>
									</td>
									<td class="description last">
										<p>The FPS of all animations.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="createAnimation" translate="no">.<a href="#createAnimation">createAnimation</a><span class="signature">( name : <span class="param-type">string</span>, start : <span class="param-type">number</span>, end : <span class="param-type">number</span>, fps : <span class="param-type">number</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Creates a new animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>start</strong>
									</td>
									<td class="description last">
										<p>The start time.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>end</strong>
									</td>
									<td class="description last">
										<p>The end time.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>fps</strong>
									</td>
									<td class="description last">
										<p>The FPS.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="getAnimationDuration" translate="no">.<a href="#getAnimationDuration">getAnimationDuration</a><span class="signature">( name : <span class="param-type">string</span> )</span><span class="type-signature"> : number</span> </h3>
					<div class="method">
						<div class="description">
							<p>Returns the duration for the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
							</tbody>
						</table>
						<dl class="details">
							<dt class="tag-returns"><strong>Returns:</strong> The duration.</dt>
						</dl>
					</div>
					<h3 class="name name-method" id="getAnimationTime" translate="no">.<a href="#getAnimationTime">getAnimationTime</a><span class="signature">( name : <span class="param-type">string</span> )</span><span class="type-signature"> : number</span> </h3>
					<div class="method">
						<div class="description">
							<p>Returns the time for the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
							</tbody>
						</table>
						<dl class="details">
							<dt class="tag-returns"><strong>Returns:</strong> The time.</dt>
						</dl>
					</div>
					<h3 class="name name-method" id="playAnimation" translate="no">.<a href="#playAnimation">playAnimation</a><span class="signature">( name : <span class="param-type">string</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Plays the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="setAnimationDirectionBackward" translate="no">.<a href="#setAnimationDirectionBackward">setAnimationDirectionBackward</a><span class="signature">( name : <span class="param-type">string</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Sets the animation playback direction to &quot;backward&quot; for the
defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="setAnimationDirectionForward" translate="no">.<a href="#setAnimationDirectionForward">setAnimationDirectionForward</a><span class="signature">( name : <span class="param-type">string</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Sets the animation playback direction to &quot;forward&quot; for the
defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="setAnimationDuration" translate="no">.<a href="#setAnimationDuration">setAnimationDuration</a><span class="signature">( name : <span class="param-type">string</span>, duration : <span class="param-type">number</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Sets the duration to the given value for the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>duration</strong>
									</td>
									<td class="description last">
										<p>The duration to set.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="setAnimationFPS" translate="no">.<a href="#setAnimationFPS">setAnimationFPS</a><span class="signature">( name : <span class="param-type">string</span>, fps : <span class="param-type">number</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Sets the FPS to the given value for the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>fps</strong>
									</td>
									<td class="description last">
										<p>The FPS to set.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="setAnimationTime" translate="no">.<a href="#setAnimationTime">setAnimationTime</a><span class="signature">( name : <span class="param-type">string</span>, time : <span class="param-type">number</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Sets the time to the given value for the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>time</strong>
									</td>
									<td class="description last">
										<p>The time to set.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="setAnimationWeight" translate="no">.<a href="#setAnimationWeight">setAnimationWeight</a><span class="signature">( name : <span class="param-type">string</span>, weight : <span class="param-type">number</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Sets the weight to the given value for the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
								<tr>
									<td class="name">
										<strong>weight</strong>
									</td>
									<td class="description last">
										<p>The weight to set.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="stopAnimation" translate="no">.<a href="#stopAnimation">stopAnimation</a><span class="signature">( name : <span class="param-type">string</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Stops the defined animation.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>name</strong>
									</td>
									<td class="description last">
										<p>The animation name.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
					<h3 class="name name-method" id="update" translate="no">.<a href="#update">update</a><span class="signature">( delta : <span class="param-type">number</span> )</span> </h3>
					<div class="method">
						<div class="description">
							<p>Updates the animations of the mesh.</p>
						</div>
						<table class="params">
							<tbody>
								<tr>
									<td class="name">
										<strong>delta</strong>
									</td>
									<td class="description last">
										<p>The delta time in seconds.</p>
									</td>
								</tr>
							</tbody>
						</table>
					</div>
				<h2 class="subsection-title">Source</h2>
				<p>
					<a href="https://github.com/mrdoob/three.js/blob/master/examples/jsm/misc/MorphBlendMesh.js" translate="no" target="_blank" rel="noopener">examples/jsm/misc/MorphBlendMesh.js</a>
				</p>
			</article>
		</section>
<script src="../scripts/linenumber.js"></script>
<script src="../scripts/page.js"></script>
</body>
</html>